﻿using System.Configuration;

namespace GSQ.DataAccess
{
    public class Connection
    {
        public static string GetConnectionString
        {
            get
            {
                string DbName = ConfigurationManager.AppSettings.Get("DbName");
                string DbUser = ConfigurationManager.AppSettings.Get("DbUser");
                string DbServer = ConfigurationManager.AppSettings.Get("DbServer");
                string DbPassWord = ConfigurationManager.AppSettings.Get("DbPassWord");
                string IntegratedSecurity = ConfigurationManager.AppSettings.Get("IntegratedSecurity");
                string strConnection = @"Data Source=" + DbServer + ";Initial Catalog=" + DbName + ";Persist Security Info=false;User ID=" + DbUser + ";MultipleActiveResultSets=True;password=" + DbPassWord + ";Integrated Security=" + IntegratedSecurity;
                return strConnection;
            }
        }

    }
}
